import {inteplanListItem, interviewList} from "@/utils/interface"
import {getInterviewList, getinterviewRecord} from '@/services'
import {makeAutoObservable} from "mobx"

class InterviewList{
    constructor(){
        makeAutoObservable(this)
    }
    planlistItem:inteplanListItem[] = []
    interviewRecord:interviewList = {} as interviewList
    async planListItem(){
        let result = await getInterviewList();
        if(result.data){
            this.planlistItem = result.data
        }
    }    
    async getinterviewRecord(interviewId?:string){
        let result = await getinterviewRecord(String(interviewId));
        console.log(result);
        
        if (result.data){
            this.interviewRecord = result.data;
        }
    }

}

export default new InterviewList